<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <title>用户的列表</title>
    <style type="text/css">
        tr{
            text-align: center;
        }
    </style>
</head>
<body>
    <center>
        <table border="1" cellspacing="0" width="900" bgcolor="yellow" align="center">
            <tr>
                <th>id</th>
                <th>姓名</th>
                <th>身高</th>
                <th>体重</th>
                <th>年龄</th>
                <th>性别</th>
                <th>操作</th>
            </tr>
            {% for v in users %}
            <tr>
                <td>{{ v.id }}</td>
                <td>{{ v.username }}</td>
                <td>{{ v.weight }}</td>
                <td>{{ v.height }}</td>
                <td>{{ v.age }}</td>
                <td>
                    {% if v.sex == '1' %}
                    女
                    {% else %}
                    男
                    {% endif %}
                </td>
                <td>
                    <a href="{% url 'user_del' v.id %}">删除</a>
                    <a href="{% url 'user_edit' v.id %}">修改</a>
                </td>
            </tr>
            {% endfor %}
           
        </table>
    </center>
</body>
</html>